<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ page import="com.wenwu.common.utils.Status.AttachmentFrom"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<c:set var="path" value="${pageContext.request.contextPath }" />
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>基本信息表单</title>
<script type="text/javascript" src="${path}/js/scripts/bootstart.js"></script>
<link rel="stylesheet" type="text/css" href="${path}/css/focus.css" />
</head>
<body>
	<script type="text/plain" id="myEditorFile"></script>
	<form id="registerForm" method="post">
		<div style="display: none;">
			<input name="mRelicsId" class="mini-textbox" />
		</div>
		<div class="form_nav">
			<table width="100%" cellpadding="4" cellspacing="0">
				<tr>
					<td width="10%" class="xx_bt nonebor">信息库编号:</td>
					<td width="24%" class="xx_type  nonebor"><input
						name="mRelicsNo" style="width: 90%;" class="mini-textbox"
						vtype="maxLength:100" /><span class="required_cls">*</span></td>
					<td width="10%" class="xx_bt nonebor">总登记号:</td>
					<td width="23%" class="xx_type  nonebor"><input name="mRegisterId"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls"> </span></td>
					<td width="10%" class="xx_bt nonebor">辅助账号类别1:</td>
					<td width="23%" class="xx_type  nonebor"><input name="mAssistType1"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls"> </span></td>
				</tr>
				<tr>
					<td class="xx_bt">辅助账号号码1:</td>
					<td class="xx_type"><input name="mAssistNum1" style="width: 90%;"
						class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls"> </span></td>
					<td class="xx_bt">辅助账号类别2:</td>
					<td class="xx_type"><input name="mAssistType2"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls"> </span></td>
					<td class="xx_bt">辅助账号号码2:</td>
					<td class="xx_type"><input name="mAssistNum2"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls"> </span></td>
				</tr>
				<tr>
					<td class="xx_bt">其他账号:</td>
					<td class="xx_type"><input name="mOtherNum"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls"> </span></td>
					<td class="xx_bt">原名:</td>
					<td class="xx_type"><input name="mOldName"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">现定名:</td>
					<td class="xx_type"><input name="mName"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
				</tr>
				<tr>
					<td class="xx_bt">类别:</td>
					<td class="xx_type"><input class="mini-combobox"
						showNullItem="true"
						url="${path}/mgr/dictionary/showListByKey?dicKey=14"
						nullItemText="请选择类别" name="mType" style="width: 90%;"
						textField="dicValue" valueField="dicValue" allowInput="false" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">年代类型:</td>
					<td class="xx_type"><input class="mini-combobox"
						showNullItem="true"
						url="${path}/mgr/dictionary/showListByKey?dicKey=1"
						nullItemText="请选择年代类型" name="mYearType" style="width: 90%;"
						textField="dicValue" valueField="dicValue" allowInput="false" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">地址学年代:</td>
					<td class="xx_type"><input name="geologyYear"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
			</tr>
			<tr>
					<td class="xx_bt">考古学年代:</td>
					<td class="xx_type"><input class="mini-combobox"
						showNullItem="true"
						url="${path}/mgr/dictionary/showListByKey?dicKey=2"
						nullItemText="请选择考古学年代" name="relicsYear" style="width: 90%;"
						textField="dicValue" valueField="dicValue" allowInput="false" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">中国历史年代:</td>
					<td class="xx_type"><input class="mini-combobox"
						showNullItem="true"
						url="${path}/mgr/dictionary/showListByKey?dicKey=3"
						nullItemText="请选择中国历史年代" name="historyYear" style="width: 90%;"
						textField="dicValue" valueField="dicValue" allowInput="false" /><span
						class="required_cls">*</span></td>
						<td class="xx_bt">公元纪年:</td>
					<td class="xx_type"><input class="mini-combobox"
						showNullItem="true"
						url="${path}/mgr/dictionary/showListByKey?dicKey=15"
						nullItemText="请选择公元纪年" name="christianYear" style="width: 90%;"
						textField="dicValue" valueField="dicValue" allowInput="false" /><span
						class="required_cls">*</span></td>
				</tr>
				<tr>
					<td class="xx_bt">精确年代:</td>
					<td class="xx_type"><input name="mYear" style="width: 90%;"
						class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">形态类别:</td>
					<td class="xx_type"><input name="mShapeType"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">形态特征:</td>
					<td class="xx_type"><input name="mShapeCharacter"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
				</tr>
				<tr>

					<td class="xx_bt">质地类别:</td>
					<td class="xx_type"><input class="mini-combobox"
						showNullItem="true"
						url="${path}/mgr/dictionary/showListByKey?dicKey=16"
						nullItemText="请选择质地类别" name="mTextureType" style="width: 90%;"
						textField="dicValue" valueField="dicValue" allowInput="false" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">质地:</td>
					<td class="xx_type"><input name="mTexture"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">颜色:</td>
					<td class="xx_type"><input name="mColor"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
				</tr>
				<tr>
					
					<td class="xx_bt">光泽:</td>
					<td class="xx_type"><input name="mGloss"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">尺寸单位:</td>
					<td class="xx_type"><input class="mini-combobox"
						showNullItem="true"
						url="${path}/mgr/dictionary/showListByKey?dicKey=17"
						nullItemText="请选择尺寸单位" name="mSizeUnit" style="width: 90%;"
						textField="dicValue" valueField="dicValue" allowInput="false" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">尺寸:</td>
					<td class="xx_type"><input name="mSize"
						style="width: 90%;" class="mini-textbox" vtype="float" /><span
						class="required_cls">*</span></td>
				</tr>
				<tr>
					
					<td class="xx_bt">质量单位:</td>
					<td class="xx_type"><input class="mini-combobox"
						showNullItem="true"
						url="${path}/mgr/dictionary/showListByKey?dicKey=18"
						nullItemText="请选择质量单位" name="mWeightUnit" style="width: 90%;"
						textField="dicValue" valueField="dicValue" allowInput="false" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">质量:</td>
					<td class="xx_type"><input name="mWeight" style="width: 90%;"
						class="mini-textbox" vtype="float" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">容积单位:</td>
					<td class="xx_type"><input class="mini-combobox"
						showNullItem="true"
						url="${path}/mgr/dictionary/showListByKey?dicKey=19"
						nullItemText="请选择容积单位" name="mVolumeUnit" style="width: 90%;"
						textField="dicValue" valueField="dicValue" allowInput="false" /><span
						class="required_cls">*</span></td>
				</tr>
				<tr>
					
					<td class="xx_bt">容积:</td>
					<td class="xx_type"><input name="mVolume" style="width: 90%;"
						class="mini-textbox" vtype="float" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">实际数量:</td>
					<td class="xx_type"><input name="mNumber"
						style="width: 90%;" class="mini-textbox" vtype="float" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">实际数量单位:</td>
					<td class="xx_type"><input name="mNumberUnit"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
				</tr>
				<tr>
					
					<td class="xx_bt">传统数量:</td>
					<td class="xx_type"><input name="mTraditionNumber"
						style="width: 90%;" class="mini-textbox" vtype="float" />
						<span class="required_cls">*</span></td>
					<td class="xx_bt">传统数量单位:</td>
					<td class="xx_type"><input name="mTraditionNumberUnit"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">附件及附属物名称:</td>
					<td class="xx_type"><input name="mAttachmentName"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
				</tr>
				<tr>
					
					<td class="xx_bt">附件及附属物数量:</td>
					<td class="xx_type"><input name="mAttachmentNumber"
						style="width: 90%;" class="mini-textbox" vtype="float" />
						<span class="required_cls">*</span></td>
					
					<td class="xx_bt">鉴定日期:</td>
					<td class="xx_type"><input class="mini-datepicker"
						style="width: 90%;" allowInput="false" name="mIdentifyDate"
						format="yyyy-MM-dd" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">鉴定机构:</td>
					<td class="xx_type"><input name="mIdentifyOrgan"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
				</tr>
				<tr>
					<td class="xx_bt">鉴定意见:</td>
					<td class="xx_type" colspan="5"><input name="mIdentifyAdvice"
						style="width: 97%;" class="mini-textarea" /><span
						class="required_cls">*</span></td>
				</tr>
				
				<tr>
					<td class="xx_bt">鉴定人:</td>
					<td class="xx_type"><input name="mIdentifyPerson" emptyText="需要两位及以上专家"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" />
						<span class="required_cls">*</span></td>
					<td class="xx_bt">文物级别:</td>
					<td class="xx_type"><input class="mini-combobox"
						showNullItem="true"
						url="${path}/mgr/dictionary/showListByKey?dicKey=20"
						nullItemText="请选择文物级别" name="mRelicsLever" style="width: 90%;"
						textField="dicValue" valueField="dicValue" allowInput="false" />
						<span class="required_cls">*</span></td>
					<td class="xx_bt">保密级别:</td>
					<td class="xx_type"><input class="mini-combobox"
						showNullItem="true"
						url="${path}/mgr/dictionary/showListByKey?dicKey=23"
						nullItemText="请选择保密级别" name="mSecrecyLever" style="width: 90%;"
						textField="dicValue" valueField="dicValue" allowInput="false" /><span
						class="required_cls">*</span></td>
				</tr>
				
				<tr>
					<td class="xx_bt">收藏单位:</td>
					<td class="xx_type"><input name="mInstoreOrgan"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">保持方法:</td>
					<td class="xx_type"><input name="mSavePosition"
						style="width: 90%;" class="mini-textbox" vtype="maxLength:100" /><span
						class="required_cls">*</span></td>
					<td class="xx_bt">来源:</td>
					<td class="xx_type"><input class="mini-combobox"
						showNullItem="true"
						url="${path}/mgr/dictionary/showListByKey?dicKey=22"
						nullItemText="请选择来源" name="mRelicsOrigin" style="width: 90%;"
						textField="dicValue" valueField="dicValue" allowInput="false" /><span
						class="required_cls">*</span></td>
				</tr>
				<tr>
					<td class="xx_bt">流传经历:</td>
					<td class="xx_type" colspan="5"><input name="mSpread"
						style="width: 97%;" class="mini-textarea" /><span
						class="required_cls">*</span></td>
				</tr>
				<tr>
					<td class="xx_bt">形态描述:</td>
					<td class="xx_type" colspan="5"><input name="mDesc"
						style="width: 97%;" class="mini-textarea" /><span
						class="required_cls">*</span></td>
				</tr>
				<c:if test="${param.flag=='edit' || param.flag=='show'}">
					<tr>
						<td class="xx_bt">其它信息:</td>
						<td class="xx_type" colspan="5">
							<a class="mini-button" onclick="addform.mcultureAdd">文化面貌</a> 
							<a class="mini-button" onclick="addform.mrepairAdd">完残修复情况</a>
							<a class="mini-button" onclick="addform.audiovisualAdd">声像资料</a> 
					</tr>
			</c:if>
			</table>
		</div>
		<div style="text-align: center; padding: 10px;">、
			<c:if test="${param.flag!='show'}">
			<a class="mini-button" onclick="addform.saveData" id="sub_button"
				iconCls="icon-save" style="width: 60px; margin-right: 20px;">保存</a>
			</c:if>
			<a iconCls="icon-cancel" class="mini-button"
				onclick="$.form.onCancel()" style="width: 60px;">取消</a>
		</div>
	</form>
	
</body>
<script type="text/javascript" src="${path}/js/scripts/dataform.js"></script>
<script type="text/javascript" charset="utf-8"
	src="${path}/js/scripts/swfupload/swfupload.js"></script>
<script type="text/javascript"
	src="${path}/js/scripts/plugin/ueditor/ueditor.config.js"></script>
<script type="text/javascript"
	src="${path}/js/scripts/plugin/ueditor/ueditor.all.js"></script>
<script type="text/javascript" src="${path}/js/upload.js"></script>
<script type="text/javascript" src="${path}/js/scripts/datagrid.js"></script>
<script type="text/javascript" src="${path}/js/message.js"></script>
<script type="text/javascript">
	$(function() {
		var doc = $(document);
		$.form.init(); //初始化表单
		window.addform = {};
		addform.saveData = function() {
			var form = new mini.Form("#registerForm");
			form.validate();
			if (form.isValid() == false) {
				return;
			}
			$.form.saveData({
				url : "${path}/mgr/mregister/addregister",
				showMsg : true,//是否显示提示信息（返回参数必须是msg，json类型数据）
				id : "registerForm"
			});
		};
		addform.mcultureAdd = function() {
			var mRelicsId = $("input[name=mRelicsId]").val();
			var mName = encodeURI(encodeURI($("input[name=mName]").val()));
			$.form.edit({
				url : "${path}/mgr/mculture/cultureform?flag=${param.flag}&mRelicsId="+mRelicsId+"&relicsName="+mName,
				title : "文物面貌添加/修改",
				formId : "cultureForm",
				fieldId : "mRelicsId",
				fieldIdValue:mRelicsId,
				width : doc.width() * 0.9 + "px",
				height : doc.height() * 0.9 + "px",
				dataUrl : "${path}/mgr/mculture/showMCuform?mRelicsId="+mRelicsId
			});
		};
		addform.mrepairAdd = function() {
			var mRelicsId = $("input[name=mRelicsId]").val();
			var mName = encodeURI(encodeURI($("input[name=mName]").val()));
			$.form.edit({
				url : "${path}/mgr/mrepair/repairform?flag=${param.flag}&mRelicsId="+mRelicsId+"&relicsName="+mName,
				title : "完残情况添加/修改",
				formId : "repairForm",
				fieldId : "mRelicsId",
				fieldIdValue:mRelicsId,
				width : doc.width() * 0.8 + "px",
				height : doc.height() * 0.6 + "px",
				dataUrl : "${path}/mgr/mrepair/showMRepairform?mRelicsId="+mRelicsId
			});
		};
		addform.audiovisualAdd = function() {
			var mRelicsId = $("input[name=mRelicsId]").val();
			var mName = encodeURI(encodeURI($("input[name=mName]").val()));
			$.form.edit({
				url : "${path}/mgr/maudiovisual/audiovisualform?flag=${param.flag}&mRelicsId="+mRelicsId+"&relicsName="+mName,
				title : "声像影片添加/修改",
				formId : "repairForm",
				fieldId : "mRelicsId",
				fieldIdValue:mRelicsId,
				width : doc.width() * 0.8 + "px",
				height : doc.height() * 0.6 + "px",
				dataUrl : "${path}/mgr/maudiovisual/showAudiovisualform?mRelicsId="+mRelicsId
			});
		};
	});
</script>
</html>